package com.example.teesystem.service;

import com.example.teesystem.common.utils.Response;
import com.example.teesystem.entity.User;
import com.baomidou.mybatisplus.extension.service.IService;
import com.example.teesystem.entity.vo.PageResponseVo;
import com.example.teesystem.entity.vo.user.UserSelectVo;
import com.example.teesystem.entity.vo.user.UserSelectVo2;
import com.example.teesystem.entityDto.UserList;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
* @author 12510
* @description 针对表【t_user】的数据库操作Service
* @createDate 2022-03-23 09:49:07
*/
public interface UserService extends IService<User> {
    User getMyMessage(String account,String password);
    String getSaltByUid(int uid);
    boolean login(int uid, String passwordMD5);
    int getUIdByAccount(String account);
    String getToken(User user);
    void logout(int uid);
    Map<Integer, Float> CourseIssueCorrectRate(int studentId);
    Map<Integer, Float> CourseMeanScore(int studentId);
    Response register(User user);
    Response updateMyMessage(String username, String gender, Date birthday, String name, String academy, int grade, int classes, String mail,int uid);
    Response updatePassword(String oldPassword,String newPassword);
    PageResponseVo<UserList> getUser(UserSelectVo userSelectVo);
    Response getUserMsg(int id);
    Response getUserByMsg(UserSelectVo2 userSelectVo2);
    Response updateUserAccountType(Integer uid, Integer accountType);
    Response updateUserPassword(Integer uid, String password);
    Response getUidByAccount(List<String> list);
    Response getEstimateOfStudent(int studentId);
    Response GetStudentEstimateByCourses(int studentId);
    void updateAvatar(String avatarUrl);
    void loginSuccess(int id);
    Integer getLoginScore();
    Response studentEvaluate(int courseId,Date startTime,Date endTime);
}
